using ThingsEdge.Exchange.Contracts;

namespace Digitalmes.Application.Scada.Commands;

/// <summary>
/// 产品出站命令。
/// </summary>
public sealed record OutboundCommand : IRequest<ScadaResult>
{
    /// <summary>
    /// 线体编号
    /// </summary>
    [NotNull]
    public string? LineCode { get; init; }

    /// <summary>
    /// 工位编号
    /// </summary>
    [NotNull]
    public string? WsCode { get; init; }

    /// <summary>
    /// SN 码
    /// </summary>
    [NotNull]
    public string? SN { get; init; }

    /// <summary>
    /// 出站的状态结果
    /// </summary>
    public PassEnum PassResult { get; init; }

    /// <summary>
    /// 节拍时长
    /// </summary>
    public double? CycleTime { get; init; }

    /// <summary>
    /// 过程数据集合
    /// </summary>
    [NotNull]
    public IReadOnlyList<PayloadData>? AttachData { get; init; }
}
